package com.wayhome.srpingbootmybatis.kafka;

import com.alibaba.fastjson.JSON;
import lombok.extern.slf4j.Slf4j;
import org.apache.kafka.clients.consumer.ConsumerRecord;
import org.springframework.kafka.annotation.KafkaListener;
import org.springframework.kafka.support.Acknowledgment;
import org.springframework.stereotype.Component;

import java.util.List;

@Slf4j
@Component
public class KafkaConsumer {


    @KafkaListener(topics = "ims-hb", groupId = "ims-test-group")
    public void TestConsumer(String message, Acknowledgment ack) {
        log.info("ims-test consumer:{}", message);
        ack.acknowledge();
    }

}
